def copy_file(src,dest):
    try:
        src_file = open(src, 'rb')
        dest_file = open(dest,'wb')
        for data in src_file.readlines():
            dest_file.write(data)
    finally:
        src_file.close()
        dest_file.close()

# copy_file('E:\\kh\\wallpaper\\bloodborne-background-1.jpg','test.jpg')
copy_file('a.txt','haha.txt')

